package com.karson.admin.task;

import com.karson.service.service.AlbumInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

/**
 * @author ZKS
 */
@Component
public class ComputedRateTask {
    @Autowired
    private AlbumInfoService albumInfoService;
    @Scheduled(cron = "0 0/30 * * * ?")
    public void computedRate() {
        try {
            albumInfoService.computedRate();
        }catch (Exception e) {
            e.printStackTrace();
        }

    }
}
